<include file="Public:head" />
<include file="Public:header" />
<include file="Public:left" />
<section id='content'>
    <div class='container-fluid'>
        <div class='row-fluid' id='content-wrapper'>
            <div class='span12'>
                <div class='row-fluid'>
                    <div class='span12'>
                        <div class='page-header'>
                            <h1 class='pull-left'>
                                <i class='icon-ok'></i>
                                <span>修改登陆用户</span>
                            </h1>
                        </div>
                    </div>
                </div>
                <div class='row-fluid'>
                    <div class='span12 box'>
                        <div class='box-header blue-background'>
                            <div class='title'>修改用户</div>
                        </div>
                        <div class='box-content'>
                            <form class='form form-horizontal validate-form' style='margin-bottom: 0;' action="{:U('User/edit_user')}" method="post"/>
                                <div class='control-group'>
                                    <label class='control-label' for='validation_name'>登录名</label>
                                    <div class='controls'>
                                        <input data-rule-minlength='2' data-rule-required='true' id='validation_name' name='validation_name' placeholder='{$data.uname}' type='text' />
                                    </div>
                                </div>
                                
                                <div class='control-group'>
                                    <label class='control-label' for='validation_password'>登陆密码</label>
                                    <div class='controls'>
                                        <input data-rule-minlength='6' name='validation_password' placeholder='Password' type='password' />
                                    </div>
                                </div>
                                <!-- <div class='control-group'>
                                    <label class='control-label' for='validation_password_confirmation'>确认密码</label>
                                    <div class='controls'>
                                        <input data-rule-equalto='#validation_password' data-rule-required='true' id='validation_password_confirmation' name='validation_password_confirmation' placeholder='Password confirmation' type='password' />
                                    </div>
                                </div> -->
                                <!-- <div class='control-group'>
                                    <label class='control-label' for='validation_agree'>用户权限</label>
                                    <div class='controls'>
                                        <label class='checkbox'>
                                            <input data-rule-required='true' id='validation_agree' name='validation_agree' type='checkbox' value='' />
                                        </label>
                                    </div>
                                </div> -->
                                
                                <div class='control-group'>
                                    <label class='control-label' for='validation_select'>用户组别</label>
                                    <div class='controls'>
                                        <select data-rule-required='true' id='validation_select' name='validation_select'>

                                            <option value="1"/>总管理员
                                            <option value="2"/>公司员工
                                            <option value="3"/>经销商
                                        </select>
                                    </div>
                                </div>
                                <script type='text/javascript'>
                                    var opts = document.getElementById("validation_select");
                                    var value = "{$data.group}";
                                    if(value!=""){
                                        for(var i=0;i<opts.options.length;i++){
                                            if(value==opts.options[i].value){
                                            opts.options[i].selected = 'selected';
                                            }
                                        }
                                    }
                                </script>
                                <div class='form-actions' style='margin-bottom:0'>
                                    <input  type='hidden' name="aaid" value="{$Think.get.aid}"/>
                                    <button class='btn btn-primary' type='submit'>
                                        <i class='icon-save'></i>
                                        保存用户
                                    </button>
                                </div>
                            </form>
                        </div>
                    </div>
                </div>
                
            </div>
        </div>
    </div>
</section>
</div>
<include file="Public:bottom" />
<script type="text/javascript">
    $(document).ready(function () {
      $("ul[class='nav nav-stacked']").removeClass('in');
      $("#admin").addClass('in');
      $("li[class='guan']").removeClass('active');
      $("#adduser").addClass('active');
    });
</script>